﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using Phoenix.AppCode.Entities;
using Phoenix.AppCode.Data;
using System.Data;

namespace Phoenix.AppCode.Bussiness
{
    public class PortShippingScheduleService
    {
        public PortShippingScheduleService() 
        {
            //
            // TODO: Add constructor logic here
            //    
        }
        public static DataTable PortShippingGetDate(int id, String dfrom, String dto)
        {
            PortShippingScheduleDAO portshipDAO = new PortShippingScheduleDAO();
            return portshipDAO.PortShippingGetDate(id, dfrom, dto);
        }
        public static DataTable PortShippingGetListID(int id)
        {
            PortShippingScheduleDAO portshipDAO = new PortShippingScheduleDAO();
            return portshipDAO.PortShippingGetListID(id);
        }
        #region Backend Method
        /// <summary>
        /// Create 
        /// </summary>
        /// <param name="portshippingschedule"></param>
        public static void Create(PortShippingSchedule portshippingschedule)
        {
            PortShippingScheduleDAO idportshippingscheduleDAO = new PortShippingScheduleDAO();
            idportshippingscheduleDAO.Create(portshippingschedule);
        }

        /// <summary>
        /// Edit
        /// </summary>
        /// <param name="portshippingschedule"></param>
        public static void Edit(PortShippingSchedule portshippingschedule)
        {
            PortShippingScheduleDAO idportshippingscheduleDAO = new PortShippingScheduleDAO();
            idportshippingscheduleDAO.Edit(portshippingschedule);
        }

        /// <summary>
        /// On/Off
        /// </summary>
        /// <param name="portshippingschedule"></param>
        public static void OnOff(PortShippingSchedule portshippingschedule)
        {
            PortShippingScheduleDAO idportshippingscheduleDAO = new PortShippingScheduleDAO();
            idportshippingscheduleDAO.OnOff(portshippingschedule);
        }

        /// <summary>
        /// Delete
        /// </summary>
        /// <param name="portshippingschedule"></param>
        public static void Delete(PortShippingSchedule portshippingschedule)
        {
            PortShippingScheduleDAO idportshippingscheduleDAO = new PortShippingScheduleDAO();
            idportshippingscheduleDAO.Delete(portshippingschedule);
        }

        /// <summary>
        /// Show category all
        /// </summary>
        /// <param name="language"></param>
        /// <returns></returns>
        public static DataTable PortShippingScheduleList()
        {
            PortShippingScheduleDAO idportshippingscheduleDAO = new PortShippingScheduleDAO();
            return idportshippingscheduleDAO.PortShippingScheduleList();
        }

        /// <summary>
        /// Show all
        /// </summary>
        /// <param name="language"></param>
        /// <returns></returns>
        public static DataTable PortShippingScheduleListById(int idtrackinge)
        {
            PortShippingScheduleDAO idportshippingscheduleDAO = new PortShippingScheduleDAO();
            return idportshippingscheduleDAO.PortShippingScheduleListById(idtrackinge);
        }

        /// <summary>
        /// Show data by ID
        /// </summary>
        /// <param name="idportshippingschedule"></param>
        /// <returns></returns>
        public static DataTable PortShippingScheduleList_GetByID(int idportshippingschedule)
        {
            PortShippingScheduleDAO idportshippingscheduleDAO = new PortShippingScheduleDAO();
            return idportshippingscheduleDAO.PortShippingScheduleList_GetByID(idportshippingschedule);
        }

        /// <summary>
        /// Get ID to edit or delete 
        /// </summary>
        /// <param name="idportshippingschedule"></param>
        /// <returns></returns>
        public static PortShippingSchedule GetPortShippingScheduleByID(int idportshippingschedule)
        {
            PortShippingScheduleDAO idportshippingscheduleDAO = new PortShippingScheduleDAO();
            return idportshippingscheduleDAO.GetPortShippingScheduleByID(idportshippingschedule);
        }
        #endregion
    }
}